<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
  <style>
    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }
    body {
      width: 100%;
      height: 100%;
    }
    .container {
      width: 1800px;
      padding: 0 80px;
      margin: 0 auto;
      overflow: hidden;
    }
    ul {
      position: relative;
      width: 1600px;
      margin: 0 auto;
    }
    ul li {
      list-style-type: none;
      float: right;
      width: 400px;
      height: 600px;
      background-image: url('../../images/img/1.png');
    }
    .clearfix {
      zoom: 1;
    }
    .clearfix::after {
      content: "";
      height: 0;
      line-height: 0;
      visibility: hidden;
      display: block;
      clear: both;
    }
  </style>
  <script src="../../JavaScript/jQuery.js"></script>
</head>
<body>
  <div class="container" id="nav">
    <ul class="clearfix">
      <li></li>
      <li></li>
      <li></li>
      <li></li>
    </ul>
  </div>
  <script>
    $(function () {
      let liObjs = $('ul>li');
      liObjs.each(function (i) {
        $(this).css('backgroundImage','url(../../images/img/' + (i+1) + '.png)');
      });

      liObjs.mouseenter(function () {
        $(this).css({'width':'1210px','transition':'0.5s'}).siblings().css({'width':'130px','transition':'0.5s'});
      }).mouseout(function () {
        liObjs.css({'width': '400px','transition':'0.5s'});
      });
    });
  </script>
</body>
</html>